package com.japp.manager.service;

import java.io.Serializable;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.japp.base.BaseService;
import com.japp.manager.bean.QuantizaTionBean;
import com.japp.manager.mapper.QuantizaTionMapper;
import com.japp.tools.common.JappLog;
import com.japp.tools.page.Page;

/**
 * 研究报告
 * @author Administrator
 *
 */
@Service
@Transactional(rollbackFor = Exception.class)
public class QuantizaTionService implements BaseService{
	@Autowired
	private QuantizaTionMapper quantizaTionMapper;
	
	public QuantizaTionBean get(Serializable pk) {
		return null;
	}

	
	public Page<QuantizaTionBean> getPage(Page<QuantizaTionBean> po, QuantizaTionBean obj) {
		try {
			Page<QuantizaTionBean> page = quantizaTionMapper.getPage(po, obj);
			return page;
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return null;
	}

	public QuantizaTionBean findQuantizaTionByBean(QuantizaTionBean quantizaTion){
		return quantizaTionMapper.findQuantizaTionByBean(quantizaTion);
	}
	
	public List<QuantizaTionBean> queryQuantizaTionAll() {
		try {
			return quantizaTionMapper.queryQuantizaTionAll();
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return null;
	}
	
	public QuantizaTionBean findQuantizaTionById(int quantizaTionId) {
		try {
			return quantizaTionMapper.findQuantizaTionById(quantizaTionId);
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return null;
	}

	
	public int insertQuantizaTion(QuantizaTionBean quantizaTion) {
		try {
			return quantizaTionMapper.insertQuantizaTion(quantizaTion);
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return 0;
	}
	public int deleteQuantizaTion(String[] keys) {
		try {
			int rel = quantizaTionMapper.deleteQuantizaTion(keys);
			return rel;
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return 0;
	}

	
	public int updateQuantizaTion(QuantizaTionBean quantizaTion) {
		try {
			return quantizaTionMapper.updateQuantizaTion(quantizaTion);
		} catch (Exception e) {
			JappLog.log.error("",e);
		}
		return 0;
	}

}
